From: Rene Engelhard Date: Sun, 1 Nov 2020 17:30:49 +0000 (+0100) Subject: [PATCH] use standard true. X-Git-Tag: archive/raspbian/1%7.0.4-3+rpi1~1^2~2 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/%22mailto:kde%40ewsoftware.de//%22style.css/%22/%22http:/www.example.com/%22mailto:kde%40ewsoftware.de/%22style.css/%22?a=commitdiff_plain;h=6cd682eaa09140f4a212301a9fb96ce507ed68c2;p=libreoffice.git [PATCH] use standard true. to fix build with ICU 68: /home/rene/LibreOffice/git/master/i18npool/source/calendar/calendar_gregorian.cxx: In member function 'virtual void i18npool::Calendar_gregorian::setLocalDateTime(double)': /home/rene/LibreOffice/git/master/i18npool/source/calendar/calendar_gregorian.cxx:363:40: error: 'TRUE' was not declared in this scope 363 | body->getTimeZone().getOffset( fR, TRUE, nZoneOffset, nDSTOffset, status ); | ^~~~ /usr/include/unicode/umachine.h says: @deprecated ICU 68 Use standard "true" instead. Change-Id: I45d2b0afa6a9043767af5c2cf41ba24377f2cdc4 Gbp-Pq: Name icu-68.diff --- diff --git a/i18npool/source/calendar/calendar_gregorian.cxx b/i18npool/source/calendar/calendar_gregorian.cxx index b7ae49fbd96..59ee46fa0e0 100644 --- a/i18npool/source/calendar/calendar_gregorian.cxx +++ b/i18npool/source/calendar/calendar_gregorian.cxx @@ -347,7 +347,14 @@ Calendar_gregorian::setLocalDateTime( double fTimeInDays ) "Calendar_gregorian::setLocalDateTime: " << std::fixed << fM << " rounded to " << fR); int32_t nZoneOffset, nDSTOffset; UErrorCode status = U_ZERO_ERROR; - body->getTimeZone().getOffset( fR, TRUE, nZoneOffset, nDSTOffset, status ); + body->getTimeZone().getOffset( fR, +#if U_ICU_VERSION_MAJOR_NUM >= 68 + true, +#else + TRUE, +#endif + nZoneOffset, nDSTOffset, status ); + if ( !U_SUCCESS(status) ) throw ERROR; status = U_ZERO_ERROR; body->setTime( fR - (nZoneOffset + nDSTOffset), status );